package com.tim.app.server.result;

import android.os.Parcel;
import android.os.Parcelable;

import java.util.ArrayList;
import java.util.List;

/**
 * Created by wdy on 2017/8/23.
 */

public class SignInBean {


    /**
     * code : 10000
     * message : success
     * total : 1
     * res : {"hashmap":{"user":{"id":1000539,"moliFlowerCount":0,"flowerCount":0,"signCount":2,"signTime":1503452947000,"incomeMoney":0},"signArray":[1,2,3,4,5,6]}}
     */

    private String code;
    private String message;
    private int total;
    private ResBean res;

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public int getTotal() {
        return total;
    }

    public void setTotal(int total) {
        this.total = total;
    }

    public ResBean getRes() {
        return res;
    }

    public void setRes(ResBean res) {
        this.res = res;
    }

    public static class ResBean {
        /**
         * hashmap : {"user":{"id":1000539,"moliFlowerCount":0,"flowerCount":0,"signCount":2,"signTime":1503452947000,"incomeMoney":0},"signArray":[1,2,3,4,5,6]}
         */

        private HashmapBean hashmap;

        public HashmapBean getHashmap() {
            return hashmap;
        }

        public void setHashmap(HashmapBean hashmap) {
            this.hashmap = hashmap;
        }

        public static class HashmapBean implements Parcelable {
            /**
             * user : {"id":1000539,"moliFlowerCount":0,"flowerCount":0,"signCount":2,"signTime":1503452947000,"incomeMoney":0}
             * signArray : [1,2,3,4,5,6]
             */

            private UserBean user;
            private List<Integer> signArray;

            public UserBean getUser() {
                return user;
            }

            public void setUser(UserBean user) {
                this.user = user;
            }

            public List<Integer> getSignArray() {
                return signArray;
            }

            public void setSignArray(List<Integer> signArray) {
                this.signArray = signArray;
            }

            public static class UserBean implements Parcelable {
                /**
                 * id : 1000539
                 * moliFlowerCount : 0.0
                 * flowerCount : 0.0
                 * signCount : 2
                 * signTime : 1503452947000
                 * incomeMoney : 0.0
                 */

                private int id;
                private double moliFlowerCount;
                private double flowerCount;
                private int signCount;
                private long signTime;
                private double incomeMoney;

                public int getId() {
                    return id;
                }

                public void setId(int id) {
                    this.id = id;
                }

                public double getMoliFlowerCount() {
                    return moliFlowerCount;
                }

                public void setMoliFlowerCount(double moliFlowerCount) {
                    this.moliFlowerCount = moliFlowerCount;
                }

                public double getFlowerCount() {
                    return flowerCount;
                }

                public void setFlowerCount(double flowerCount) {
                    this.flowerCount = flowerCount;
                }

                public int getSignCount() {
                    return signCount;
                }

                public void setSignCount(int signCount) {
                    this.signCount = signCount;
                }

                public long getSignTime() {
                    return signTime;
                }

                public void setSignTime(long signTime) {
                    this.signTime = signTime;
                }

                public double getIncomeMoney() {
                    return incomeMoney;
                }

                public void setIncomeMoney(double incomeMoney) {
                    this.incomeMoney = incomeMoney;
                }

                @Override
                public int describeContents() {
                    return 0;
                }

                @Override
                public void writeToParcel(Parcel dest, int flags) {
                    dest.writeInt(this.id);
                    dest.writeDouble(this.moliFlowerCount);
                    dest.writeDouble(this.flowerCount);
                    dest.writeInt(this.signCount);
                    dest.writeLong(this.signTime);
                    dest.writeDouble(this.incomeMoney);
                }

                public UserBean() {
                }

                protected UserBean(Parcel in) {
                    this.id = in.readInt();
                    this.moliFlowerCount = in.readDouble();
                    this.flowerCount = in.readDouble();
                    this.signCount = in.readInt();
                    this.signTime = in.readLong();
                    this.incomeMoney = in.readDouble();
                }

                public static final Parcelable.Creator<UserBean> CREATOR = new Parcelable.Creator<UserBean>() {
                    @Override
                    public UserBean createFromParcel(Parcel source) {
                        return new UserBean(source);
                    }

                    @Override
                    public UserBean[] newArray(int size) {
                        return new UserBean[size];
                    }
                };
            }

            @Override
            public int describeContents() {
                return 0;
            }

            @Override
            public void writeToParcel(Parcel dest, int flags) {
                dest.writeParcelable(this.user, flags);
                dest.writeList(this.signArray);
            }

            public HashmapBean() {
            }

            protected HashmapBean(Parcel in) {
                this.user = in.readParcelable(UserBean.class.getClassLoader());
                this.signArray = new ArrayList<Integer>();
                in.readList(this.signArray, Integer.class.getClassLoader());
            }

            public static final Parcelable.Creator<HashmapBean> CREATOR = new Parcelable.Creator<HashmapBean>() {
                @Override
                public HashmapBean createFromParcel(Parcel source) {
                    return new HashmapBean(source);
                }

                @Override
                public HashmapBean[] newArray(int size) {
                    return new HashmapBean[size];
                }
            };
        }
    }
}
